<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
	<form action="customer.action?methodName=toAddCustomer" method="post">
		<table class="querytable" align="center">
			<tr>
				<th>客户编号</th>
				<th>客户姓名</th>
				<th>客户年龄</th>
				<th>性别</th>
				<th>身份证号码</th>
				<th>客户号码</th>
				<th>地址</th>
				<th>操作</th>
			</tr>
			<c:forEach items="${customer }" var="cu">
				
				<tr>
					<td>${cu.customerId }</td>
					<td>${cu.customerName }</td>
					<td>${cu.age }</td>
					<td>
						<c:if test="${cu.gender eq '01' }">男</c:if>
						<c:if test="${cu.gender eq '02' }">女</c:if>
					</td>
					<td>${cu.IDCard }</td>
					<td>${cu.customerNum }</td>
					<td>${cu.address }</td>
					<td>
						<a href="customer.action?methodName=detailCustomer&customerId=${cu.customerId }">查询</a>
						<a href="customer.action?methodName=toUpdateCustomer&customerId=${cu.customerId }">修改</a>
						<a onclick="return confirm('确认删除该客户吗?')" href="customer.action?methodName=doDeleteCustomer&customerId=${cu.customerId }">删除</a>
					</td>
				</tr>
			</c:forEach>
			<tr>
				<td align="center" colspan="8">
					<input type="submit" value="新增用户信息" />
				</td>
			</tr>
		</table>
	</form>

<link rel="stylesheet" href="${pageContext.request.contextPath }/css/editTablestyles.css">
<script type="text/javascript" src="${pageContext.request.contextPath }/webjars/jquery/1.12.4/jquery.min.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath }/js/listTable.js"></script>

</body>
</html>